<%@page import="java.util.ArrayList"%>
<%@page import="dao.studentInfoDAO"%>
<%@page import="entity.studentInfo"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    
 
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>首页</title>
</head>
<body>

当前用户:${username}
<p/>

<table border = "1" align = "center">
<tr>
	<th colspan="10"   style="font-size:30px;">学生信息管理系统</th>
<tr>	
	<th>序号</th>
	<th>姓名</th>
	<th>学号</th>
	<th>性别</th>
	<th>出生年月</th>
	<th>籍贯</th>
	<th>爱好</th>
	<th>相片</th>
	<th width="100">备注</th>
	<th>详细信息</th>
<tr>

<!-- 学生信息开始循环 -->
<%
	studentInfoDAO stuDao = new studentInfoDAO();
    ArrayList<studentInfo> list = stuDao.getAllStudent();
   
    for(int i=0 ; i<list.size();i++)
    {
    	studentInfo stu = list.get(i);   
%>  	
<tr>
    <td><%= stu.getId()  %></td>	
    <td><%= stu.getName()  %></td>	
    <td><%= stu.getNumber()  %></td>	
    <td><%= stu.getGender()  %></td>	
    <td><%= stu.getBirthday()  %></td>	
    <td><%= stu.getNative_place()  %></td>	       <!-- 表达式 -->      
    <td><% out.print(stu.getHobby());   %></td>	   <!-- JAVA语法 -->
    <td ><a href=""> <img alt="" src="images/<%=stu.getPicture() %>"  width="100" height="100"></a></td>	
    <td><%= stu.getRemark()  %></td>	
    <td><a href="stuInfoVerbers.jsp?number=<%=stu.getNumber() %>" target="_blank">详细信息</a></td>
</tr>
<%    	
    }
%>
</table>



</body>
</html>